<template>
    <h2>{{ route.query.id ? "编辑角色" : "新增角色" }}</h2>
    <el-form>
      <el-form-item label="角色名称">
        <el-input></el-input>
      </el-form-item>
      <el-form-item label="角色描述">
        <el-input></el-input>
      </el-form-item>
      <el-form-item label="角色状态">
        <el-radio>启用</el-radio>
        <el-radio>禁用</el-radio>
      </el-form-item>
      <div>
        <el-button type="primary">保存</el-button>
      </div>
    </el-form>
  </template>
  
  <script lang="ts" setup>
  import { useRoute } from "vue-router";
  const route = useRoute();
  </script>
  
  <style lang="less" scoped></style>